Skip to content

fix(vendor)!: vendor files with .rej/.orig suffix #15569

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
May 21, 2025

Conversation

weihanglo
Copy link
Member

@weihanglo weihanglo commented May 21, 2025

What does this PR try to resolve?

This is meant to fixes #13191

As git sources and registry sources are considered immutable.
I don't think there is any reason excluding those files.
There might be a little chance local Git repositories might have those,
though that is a rare use case.

Alternatively,
we could reject all .rej/.orig files but Cargo.toml.orig.

How should we test and review this PR?

Test updates should be sufficient.

Additional information

This is a follow-up of #15514

@rustbot
Copy link
Collaborator

rustbot commented May 21, 2025

r? @ehuss

rustbot has assigned @ehuss.
They will have a look at your PR within the next two weeks and either review your PR or reassign to another reviewer.

Use r? to explicitly pick a reviewer

@rustbot rustbot added Command-vendor S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels May 21, 2025
@weihanglo
Copy link
Member Author

Maybe I should do it in reversed order.

weihanglo added 3 commits May 21, 2025 13:03
So that it explicitly shows what we really vendor
This is meant to fixes rust-lang#13191

As git sources and registry sources are considered immutable.
I don't think there is any reason excluding those files.
There might be a little chance local Git repositories might have those,
though that is a rare use case.

Alternatively,
we could reject all `.rej`/`.orig` files but `Cargo.toml.orig`.
@epage
Copy link
Contributor

epage commented May 21, 2025

Maybe I should do it in reversed order.

Yeah, I'd put the snapshot first

Comment on lines 618 to 619
// Temporary Cargo files
Some(".cargo-ok") => false,
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Now that we are doing fresh extractions, is this still needed?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For git checkouts we still have that, though there is no test exercising that code path. Do you want a test for it in this PR?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let's go ahead and merge this

@epage epage enabled auto-merge May 21, 2025 17:25
@epage epage added this pull request to the merge queue May 21, 2025
Merged via the queue into rust-lang:master with commit 4b3f952 May 21, 2025
23 checks passed
@weihanglo weihanglo deleted the vendor branch May 21, 2025 22:23
bors added a commit to rust-lang/rust that referenced this pull request May 23, 2025
Update cargo

9 commits in 47c911e9e6f6461f90ce19142031fe16876a3b95..68db37499f2de8acef704c73d9031be6fbcbaee4
2025-05-14 17:53:17 +0000 to 2025-05-22 14:27:15 +0000
- chore(gh): Add new-lint issue template (rust-lang/cargo#15575)
- fix(toml): Remove workaround for rustc frontmatter support (rust-lang/cargo#15570)
- fix(vendor)!: vendor files with .rej/.orig suffix (rust-lang/cargo#15569)
- fix(vendor)!: direct extraction for registry sources (rust-lang/cargo#15514)
- chore(deps): update msrv (1 version) to v1.87 (rust-lang/cargo#15530)
- Fix comment for cargo/core/compiler/fingerprint/mod.rs (rust-lang/cargo#15565)
- fix: remove unnecessary workaround in standard_lib test (rust-lang/cargo#15522)
- Allow configuring arbitrary codegen backends (rust-lang/cargo#15562)
- Update dependencies (rust-lang/cargo#15557)

r? ghost
@rustbot rustbot added this to the 1.89.0 milestone May 24, 2025
github-actions bot pushed a commit to rust-lang/miri that referenced this pull request May 25, 2025
Update cargo

9 commits in 47c911e9e6f6461f90ce19142031fe16876a3b95..68db37499f2de8acef704c73d9031be6fbcbaee4
2025-05-14 17:53:17 +0000 to 2025-05-22 14:27:15 +0000
- chore(gh): Add new-lint issue template (rust-lang/cargo#15575)
- fix(toml): Remove workaround for rustc frontmatter support (rust-lang/cargo#15570)
- fix(vendor)!: vendor files with .rej/.orig suffix (rust-lang/cargo#15569)
- fix(vendor)!: direct extraction for registry sources (rust-lang/cargo#15514)
- chore(deps): update msrv (1 version) to v1.87 (rust-lang/cargo#15530)
- Fix comment for cargo/core/compiler/fingerprint/mod.rs (rust-lang/cargo#15565)
- fix: remove unnecessary workaround in standard_lib test (rust-lang/cargo#15522)
- Allow configuring arbitrary codegen backends (rust-lang/cargo#15562)
- Update dependencies (rust-lang/cargo#15557)

r? ghost
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Command-vendor S-waiting-on-review Status: Awaiting review from the assignee but also interested parties.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Normalization of Cargo.toml can break crates with deps. that read Cargo.toml
4 participants